import request from './request'


const getArticleSelect = data =>{
    return request.zlhGet({
        url:'api/articleS',
        data
    })
}

const getArticleList = data =>{
    return request.zlhGet({
        url:'api/article',
        data
    })
}

const addArticle = data =>{
    return request.zlhPost({
        url:'api/article',
        data
    })
}

const getArticleInfo = data =>{
    return request.zlhGet({
        url:'api/article/'+data,
        data
    })
}


const deleteArticle = data =>{
    return request.zlhPost({
        url:'api/articleD',
        data
    })
}

const editArticle = (id,data) =>{
    return request.zlhPost({
        url:'api/article/'+id,
        data
    })
}


export default {
    getArticleList,
    getArticleSelect,
    addArticle,
    getArticleInfo,
    editArticle,
    deleteArticle
}
